<div id="tabs">
	<ul>
        <li id="current"><?php echo $this->Html->link(__('Các thông báo', true), array('controller' => 'z1thongbaos', 'action' => 'index',$nhanvien_id)); ?> </li>
        <li><?php echo $this->Html->link(__('Thêm thông báo mới', true), array('controller'=>'thongbaos','action' => 'add',$nhanvien_id)); ?></li>
	</ul>
</div>
<div class="z1thongbaos index">
	<h2><?php __('Danh sách thông báo bạn đã tạo');?></h2>
	<table cellpadding="0" cellspacing="0" id="tables">
	<tr>
			<th><?php echo 'STT';?></th>
			<th><?php echo 'Thông báo';?></th>
			<th><?php echo 'Ngày tạo';?></th>
			<th><?php echo 'Hiển thị';?></th>
			<th><?php echo 'Người xem';?></th>
			<th class="actions"><?php __('Lựa chọn');?></th>
	</tr>
	<?php
	$i = 0;
	foreach ($z1thongbaos as $z1thongbao):
		$class = null;
		if ($i++ % 2 == 0) {
			$class = ' class="altrow"';
		}
	?>
	<tr<?php echo $class;?>>
		<td><?php echo $i; ?>&nbsp;</td>
		<td><?php echo $z1thongbao['Z1thongbao']['noidung']; ?>&nbsp;</td>
		<td><?php echo $z1thongbao['Z1thongbao']['ngaytao']; ?>&nbsp;</td>
		<td><?php if($z1thongbao['Z1thongbao']['active']==1) echo 'Có'; else echo 'Không'; ?>&nbsp;</td>
		<td>
			<?php echo $z1thongbao['Z1thongbao']['chucdanh_id']; ?>
		</td>
		<td class="actions">
			<?php //echo $this->Html->link(__('View', true), array('action' => 'view', $z1thongbao['Z1thongbao']['id'])); ?>
			<?php //echo $this->Html->link(__('Sửa', true), array('action' => 'edit', $z1thongbao['Z1thongbao']['id'])); ?>
			<?php echo $this->Html->link(__('Xóa', true), array('controller'=>'z1thongbaos','action' => 'delete',$nhanvien_id,$z1thongbao['Z1thongbao']['id']), null, sprintf(__('Bạn muốn xóa thông báo này ?', true), $z1thongbao['Z1thongbao']['id'])); ?>
		</td>
	</tr>
<?php endforeach; ?>
	</table>
	<p>
	<?php
	echo $this->Paginator->counter(array(
	'format' => __('Trang %page%/%pages%, hiện có %count% mẫu tin', true)
	));
	?>	</p>

	<div class="paging">
		<?php echo $this->Paginator->prev('<< ' . __('Trước', true), array(), null, array('class'=>'disabled'));?>
	 | 	<?php echo $this->Paginator->numbers();?>
 |
		<?php echo $this->Paginator->next(__('Sau', true) . ' >>', array(), null, array('class' => 'disabled'));?>
	</div>
</div>
